package com.minivision.fdiot.rest.param.detect;

import com.minivision.fdiot.common.AuthParam;
import com.minivision.fdiot.entity.FaceSet;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import org.hibernate.validator.constraints.NotBlank;
import org.springframework.web.multipart.MultipartFile;

import javax.validation.constraints.Max;
import java.util.Arrays;
import java.util.List;

@Getter
@Setter
public class SearchsParam extends AuthParam {

  private static final long serialVersionUID = 4331892568980284171L;

  @ApiModelProperty(value = "人脸特征值")
  private float[] faceFeature;

  @NotBlank(message = "facesetToken must not be empty")
  @ApiModelProperty(value = "人脸库Token集合", required = true)
  private List<FaceSet> faceSets;

  @Max(100)
  @ApiModelProperty(value = "返回相似人脸数量，默认为1，最多100个")
  private int resultCount = 1;


  private String feature;

  @Override
  public String toString() {
    return "SearchsParam{" +
            "faceFeature='" + faceFeature + '\'' +
            ", faceSets=" + faceSets +
            ", resultCount=" + resultCount +
            '}';
  }
}
